<?php
//关闭报错
error_reporting(0);
session_start();
include '../sys/db.class.php';
include '../config.php';
DB::connect($dbconfig['host'],$dbconfig['user'],$dbconfig['pwd'],$dbconfig['dbname'],$dbconfig['port']);
$s = DB::affected(DB::query("SELECT Id FROM love_list"));
$data = DB::get_row("SELECT user,pwd,title,seo,foot FROM love_config WHERE Id = 1");
// if (!isset($_SESSION['wuju'])) {

// 	header('Location: ./login.php');
// }
if (!isset($_SESSION['love'])) {
  header('Location: ./login.php');
}

//退出登录
if (isset($_GET['tui'])) {
	session_destroy();
	header('Location: ./login.php');
}

include 'head.php';
if (isset($_GET['s'])) {
	switch ($_GET['s']) {
		case 'list':
			include 'list.php';
			break;
		case 'set':
			include 'set.php';
			break;
		case 'see':
			include 'see.php';
			break;
		default:
			include 'wuju.php';
			break;
	}
}else{
		include 'wuju.php';
}
?>
</body>
</html>